package com.tanxi521.springboot.service.impl;

import com.tanxi521.springboot.mapper.OnlinePlayerMapper;
import com.tanxi521.springboot.pojo.OnlinePlayer;
import com.tanxi521.springboot.service.OnlinePlayerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Author: i-xiaotian
 * @Date: 2022/4/10 1:38
 * @EMAIL: 1254806967@qq.com
 */
@Service
public class OnlinePlayerServiceImpl implements OnlinePlayerService {

    @Autowired
    OnlinePlayerMapper onlinePlayerMapper;

    @Override
    public void insert(OnlinePlayer onlinePlayer) {
        onlinePlayerMapper.insert(onlinePlayer);
    }

    @Override
    public List<OnlinePlayer> queryPlayerOnlineNumList(Long end) {
        return onlinePlayerMapper.selectPlayerOnlineNumList(end);
    }
}
